package cn.iocoder.yudao.module.eval.controller.admin.assignment.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.util.List;

@Schema(description = "管理后台 - 考评员分配 Request VO")
@Data
public class EvalEvaluatorAssignmentReqVO {

    @Schema(description = "计划ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @NotNull(message = "计划ID不能为空")
    private Long planId;

    @Schema(description = "分配列表", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "分配列表不能为空")
    private List<AssignmentItem> assignments;

    @Schema(description = "分配项")
    @Data
    public static class AssignmentItem {
        @Schema(description = "用户ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "123")
        @NotNull(message = "用户ID不能为空")
        private Long userId;

        @Schema(description = "科目ID", example = "1")
        private Long subjectId;

        @Schema(description = "通知渠道", example = "[\"system\", \"email\"]")
        private List<String> notifyChannels;
    }

}
